package one.stand.mapper;

import com.jmp.api.crm.dto.GoodsTypeListResponse;
import one.stand.model.Goods;
import one.stand.model.GoodsType;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface GoodsApiCrmPcMapper {
    List<GoodsTypeListResponse.Type> selectGoodsType(@Param("company_id") Integer companyId, @Param("name") String name);

    List<Goods> selectList(@Param("company_id") Integer companyId, @Param("name") String name);

    Integer selectNum(@Param("company_id") Integer companyId);

    /**
     * 产品分类列表
     */
    List<GoodsType> selectSelectTypeList(@Param("companyId") Integer companyId, boolean isSelect);

    /**
     * 优选产品列表
     */
    List<Goods> selectSelect(@Param("company_id") Integer companyId, @Param("nameLike") String nameLike, @Param("categoryId") Integer categoryId);

    /**
     * 产品管理
     */
    List<Goods> selectGoods(@Param("company_id") Integer companyId, @Param("nameLike") String nameLike, @Param("categoryId") Integer categoryId, @Param("type") Integer type);

    List<GoodsType> selectParent(@Param("companyId") Integer companyId);
}
